home *** CD-ROM | disk | FTP | other *** search
/ Experimental BBS Explossion 3 / Experimental BBS Explossion III.iso / compress / zip2zi31.zip / ZIP2ZIP.DOC < prev    next >
Text File  |  1993-05-31  |  12KB  |  265 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.               Documentation for ZIP2ZIP v3.1
  7.                    Release of 5/31/93
  8.                     (Copyright 1993)
  9.  
  10. ZIP2ZI31.ZIP is a set of DOS batch files intended to be used for
  11. converting .ZIP files created under PKZIP v. 1.10 TO v 2.04G,
  12. utilizing maximum compression. Now Supports ZIP files within ZIP
  13. files, as long as they are not contained on a .ZIP's Path structure.
  14.  
  15. Briefly here's what it does...
  16.  
  17.        o  Accepts Input of D:\path\, 1 or WildCard Zip File(s) To
  18.           Convert. Not necessary to be in the source files's dir.
  19.        o  Preserves Volume Label, Date and Attributes of Source.
  20.        o  Preserves Sources's Internal Path Structure, If Any.
  21.        o  Converts ZIP To Maximum Compression Using Your
  22.           PKZIP 2.04g
  23.        o  Writes a Comment To The Converted ZIP (Modifiable)
  24.        o  Skips ZIP's That Already Have a Matching Comment.
  25.        o  Keeps a Detailed LogFile of Activity For Review.
  26.           Failed Conversions are indicated. Beginning/Ending
  27.           Time/Size.
  28.        o  Can Be Run Stand Alone or In a BBS "EVENT" with minor edit.
  29.  
  30.  
  31. Zip2Zi31.Zip contains:
  32.  
  33.         ZIP2ZIP.DOC  (This File)
  34.         ZIP2-001.BAT  Preliminary First Step System Checker.
  35.                       QUICK START
  36.         ZIP2-OK2.BAT  After Checking a Sub Directory Out, Run to
  37.                       Clear Environment Variables In Case Of a
  38.                       Cancel.
  39.  
  40.         ZIP2ZIP.BAT   Main Starting Batch File
  41.         ZIP2ZIPA.BAT  Called by ZIP2ZIP To Evaluate Available
  42.                       Environment Space.
  43.         ZIP2ZIPB.BAT  Called By ZIP2ZIP To Create a Level 1 Subdir
  44.                       (Z_B)  To UnZip Into.
  45.         ZIP2ZIPC.BAT  Called By Above To Accept Files And a
  46.                       ZIPinZIP.
  47.         ZIP2ZIPD.BAT  Called By Above To Accept Files From the
  48.                       ZIPinZIPinZIP, if any.
  49.         ZIP2ZMOP.BAT  Called by Most To Clean Up Work Sub Dirs
  50.                       And/Or Read Only Files.
  51.         ZIP2-SDE.BAT  Called By Most To Check Existence Of Reserved
  52.                       Work SubDirectoy.
  53.         ZIP2-FSZ.BAT  File Logic Tester And Time And Date Capture.
  54.         ZIP2-ZNP.BAT  Checks Target .ZIP For .ZIP Files Within It's
  55.                       Path.
  56.         ZIPRDZ_B.BAT  Powerful Delete Of SubDir Z_B And It's Sub
  57.                       Directories Off The Current SubDirectory.
  58.                       Used For Your Initial Testing Only.
  59.         FILE_ID.DIZ   Description.
  60.  
  61. All of the above files were AV stamped Boone-Docks for your protect-
  62. ion. If not seen, (PKUNZIP -t) it's imperative that you satisfy your-
  63. self that everything works ok by doing extensive retests. And do
  64. BACK UP FIRST.
  65.  
  66.    ZIP2ZIP.BAT has been tested under MS DOS 5 & DR DOS 5 & 6.0.
  67.        MUST USE PKZIP 2.04g WHEN RUNNING THESE BATCH FILES !!!
  68.    AND A DOS THAT HAS THE ATTRIB.EXE -r -h -s /S SWITCH CAPABILITY
  69.  
  70. STARTUP:
  71.  
  72. To use the files within ZIP2ZI30.ZIP unzip them into:
  73.  
  74.           1. Any subdirectory that will be used as "home base"
  75.              from which the batch files will be run. If not on the
  76.              path you must then be in that subdirectory to reference
  77.              the target drive\path\ files. A RamDrive Is a _good_
  78.              area to place these files. Many small files are created
  79.              under these batch files. A RamDrive would save mechanical
  80.              wear as well as disk fragmentation. It would be a very
  81.              good idea to also copy your DOS's Attrib.exe, Find.Exe
  82.              and Comp.Exe (or .Com) there. Then you'll just have hard
  83.              disk activity on the target's drive.
  84.  
  85.           2. A sub directory that is in your Path.
  86.  
  87.    For a Quick Start..Run ZIP2-001, Then ZIP2-OK2.. following the
  88.    Prompts.  Set PKTMP (if wanted). Run ZIP2ZIP (No Parm 1)..
  89.    Otherwise PLEASE Read on...
  90.  
  91. PKxxZIP must be in the path or in #1 above. The proper version is
  92. checked for. Reserved internal file names and environment variable
  93. names are existence tested. Certain environment variables and file-
  94. names are reserved for exclusive use of these batch files. They are:
  95.  
  96.                        RESERVED NAMES
  97.  
  98.     Environment Variables:  ZTIME, ZDATE, ZNAME, FSIZE, CNZL,
  99.                             EVCHK40, EVCHK30, SAFETY, DONE_B,
  100.                             DONE_C.
  101.  
  102.     Reserved SubDirectory:  Z_B Must not exist as a SubDir immediat-
  103.                             ely off the Target SubDirectory.
  104.  
  105.     Reserved FileNames:     ZIP2ZIP.LOG, ZIP2ZIP.$$$, ZIP2ZIP.CVT,
  106.                             EV0.FLG, ZIP2-FSZ. ZIP2-FSZ.$$$,
  107.                             TEMP_$$$.BAT, #2DO_B., #2DO_C., #DONE_B.
  108.                             #DONE_C., #AT_B., #AT_C..
  109.                             ZIP2ZIP.LOG ZIP2ZIP.$$$ and ZIP2ZIP.CVT
  110.                             are written in the Target SubDir.
  111.                             Others are written to the default SubDir
  112.                             from which ZIP2ZIP was launched.
  113.  
  114. ZIP2-001.BAT checks for their existence. Resolve any conflicts.
  115. Clear the variables and files, if any, with ZIP2-OK2.BAT.
  116.  
  117. ZIP2ZIP.LOG will be written in the target's subdirectory for
  118. handy viewing after the conversion session. Move files based on
  119. your needs. The ZIP2ZIP.CVT file is available to use as a move list.
  120. Identify Zips in the Zip File's path structure. Do these manually in
  121. a safe sub directory later by unzipping (-d -Jhrs) the primary to
  122. it's SubDirs and then using this program on each until completed.
  123. See ZIP2ZIP.LOG for the reasons that a .ZIP failed the conversion.
  124.  
  125. RUNNING: Use the below syntax, after reading the next few paragraphs.
  126.          Especially the 16 character max Target length. See Testing:
  127.  
  128.      Enter the Target_Drive:\SubDir\ containing the .ZIP files to be
  129.      converted to Pkzip 2.0g Max compression.
  130.      Enter:
  131.  
  132.  
  133.               ┌──See Below Testing: about Length of 16.
  134.               │        /── Don't forget the trailing "\"
  135. ZIP2ZIP D:\TARGET\PATH\ ZIPNAME <- NO .ZIP EXTENSION, Just the Name
  136.          │               ├─ Enter * to Do All *.ZIP's in the Sub Dir
  137.          │               └─ Or WildCards Within a "Family".ZIP
  138.          │
  139.          ├──── Substitute your SubDirectory Structure. Drive Letter
  140.          └──── D: Optional Unless Target is on another drive
  141.                In other words, std DOS syntax except for the "space"
  142.                between \path\ filename
  143.  
  144. OPTIONS:
  145.  
  146. Check the PKZIP and PKUNZIP -options within ZIP2ZIP?.BAT to be sure
  147. they fit your needs.
  148.  
  149. Compression is -ex (Maximum). For Failed conversions PKZIP -e0 is
  150. used for MAX SPEED clean up in ZIP2ZMOP.BAT.
  151.  
  152. I elected to keep the original date for the resulting .ZIP file,
  153. (-k option ). You might want to change it to the newest file within
  154. the set.  -o option).
  155.  
  156. BBS event users might want to change the -options to suit a
  157. different comment file inclusion. Or add: (In ZIP2ZIPB, C, & D.BAT)
  158. PKZIP   %2 -k -d @D:\YOUR\PATH\BBS-ADD.LST line (after the initial
  159. PKUNZIP %2 -t test) to get rid of those pesky little BBS-ADD files.
  160. Or anything else "as long as we are here", etc.
  161.  
  162. GENERAL:
  163.  
  164. DOS has a Quirk in the For %%f IN ( *.EXT ) Do Cmd %%f. If a single
  165. item is present in a "*" (or wildcard list) DOS will DO the operat-
  166. ion twice. If there are 3 or more files in the list DOS will do the
  167. list,  then re do #1 and #2.  I've precluded  this with pseudo
  168. counter code, but still DOS may "lose" it's place and have to re-
  169. read a prior processed file. The imbedded comment will insure one
  170. pass only. Chech a log or two.
  171.  
  172.    OLDER DOS: (3.3 and others)
  173.  
  174.       The FIND cmd is case sensitive in MS DOS. COMP.EXE yeilds
  175.       different case in older versions (ok vs OK) DR DOS is not
  176.       case sensitive in it's default. So for older versions that
  177.       report "ok" when 2 files compare equal, change the case
  178.       FIND "OK" > to FIND "ok" > in ZIP2ZIPC.BAT and ZIP2ZIPD.BAT.
  179.       (DR and MS DOS have incompatible FIND /x  swithes.)
  180.  
  181.       This Is IMPORTANT. Older DOS versions (3.31) have no support
  182.       for a cmd of ATTRIB C:\sd\*.* -r -h -s /S. Syntax error.
  183.       Halts. Two options exist. 1. Upgrade the DOS, 2. Move the
  184.       offending file to skip it. No damage will be done with #2,
  185.       just a bother to restart and skip over firsts. A third
  186.       option of modifying the PKUNZIP options to -jhrs is NOT
  187.       recommended as the conversion won't result in a true copy.
  188.  
  189.  
  190. TESTING:
  191.  
  192. Run ZIP2-001.BAT to check for reserved names. Resolve any conflicts.
  193. Clear the variables and files, if any, with ZIP2-OK2.BAT.
  194.  
  195. Copy a few .ZIP files to a work directory (Ram Drive Ok) to
  196. test out the results on your system. It's important that the Target
  197. Path not be extremely long. DOS has a line limit of 127 bytes. The
  198. Target-Path, FileName and the command within the FOR..DO..cmd can
  199. exhaust the 127 limit. Better to use short dir names. I would
  200. consider a total length of about 16 characters for the Target
  201. Path Name as maximum. File names and paths within the .ZIP WILL
  202. affect this. A zip file name of 8 characteres, containing an
  203. internal path structure of three levels of 8 characters each and
  204. each level containg a .zip of 8 characters long will fail with
  205. a Target Path Directory of 17 characters. Worst scenario.
  206.  
  207. I suggest using a new test sub directory for a few files. Using
  208. PKZIP v 1.10, create zips in zips. Test. Create a zip file in a
  209. sub directory. PKzip from the "test" root with -mrp. Make copies
  210. for later use (copy *.zip *.110) Test the zip files. Run using
  211. the * for parameter 2 :
  212.  
  213.                 ZIP2ZIP D:\YOUR_SD\ *
  214.           (or   ZIP2ZIP D:\YOUR_SD\ AFAM?LY? )
  215.  
  216. Compare the files to the ZIP2ZIP.LOG. All activity will be shown.
  217. PKUNZIP -vt (or -vb) the converted files etc. Do anything else to
  218. properly check out a VERY powerful utility, as these batch files
  219. are.
  220.  
  221. I've already done all of this and more, but maybe I missed some
  222. condition? I created test files with problems at every level. The
  223. resulting log could be stepped thru. Nice. But all the zips in a
  224. package had to be tested. I changed it to stop processing when the
  225. first failure occurred, report it and move on. So when these are
  226. processed manually you may find other errors in a deeper level.
  227.  
  228.  
  229. Oh..and if you need to run the batch files again against those
  230. .zip files already processed, do this. Go to the subdirectory
  231. containing the .zips and CAREFULLY enter from the cmd line:
  232.  
  233.                     ECHO.>CLR.CMT
  234.                     FOR %F IN (*.ZIP) DO PKZIP %F -K -Z<CLR.CMT
  235.                     DEL CLR.CMT
  236.  
  237. No batch file to do this has been included. USE the -K option!
  238.  
  239. USING:
  240.  
  241. And lastly, after you have REALLY satisfied yourself that
  242. ZIP2ZIP.BAT does everything reliably SYSOPS can run it in their
  243. "EVENT". If The Screens are too BUSY for your taste, Rem out a
  244. few Echo statements. That's the beauty of modifiable batch files.
  245.  
  246. Other std. disclaimers apply. Be Careful. As with any software that
  247. modifies your hard drive, BACK UP FIRST. At LEAST the Production
  248. sub directory. I disclaim any responsibility for any resulting
  249. damage to your system. I have used it on my system extensively.
  250.  
  251. Please drop me a note if you have found the batch files to be of
  252. benefit. If you feel some payment is in order, please send a
  253. contribution to The American Cancer Society, or any other charity
  254. of your choice.
  255.  
  256. Do not modify these batch files and re-distribute them.
  257.  
  258. Robert Boone
  259. P.O. Box 11100
  260. Houston, TX 77293
  261.  
  262. CoSysop: Ye Olde Bailey BBS  713.520.1569
  263. Compuserve Infomation Services  70070,511
  264. UseNet/InterNet   robert.boone@yob.sccsi.com
  265.